﻿using System.Collections.Generic;
using PicStore.Model;

namespace PicStore.BLL.Interface
{
    public interface IUserService
    {
        /// <summary>
        /// 根据用户Id获取用户信息
        /// </summary>
        User GetUser(int userId);

        /// <summary>
        /// 根据用户登录名获取用户信息
        /// </summary>
        User GetUser(string userName);

        List<User> GetAllUsers(string name);
        List<Role> GetRoles();

        //屏蔽用户
        void ShieldUser(int userId);

        //解除屏蔽
        void UnShieldUser(int userId);

        void UpdateUser(int userId, string email, string department, string phone, string mobile, int roleId);

        void CreateUser(string userName, string password, string email, string department, string phone, string mobile, int roleId);

        void ResetPassword(int userId, string password);

        void ChangePassword(string userName, string oldPassword, string newPassword);

        bool ValidateUser(string userName, string password);
    }
}
